package com.sjl.db137.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.sjl.db137.entity.Menu;
import com.sjl.db137.entity.User;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * @Author: zero domain
 * @CreateTime: 2024/12/24 11:49
 * @Description: TODO
 * @Version: 1.0
 */
@Mapper
public interface UserMapper extends BaseMapper<User> {

    /***
     * 登录
     * @param uname 用户名
     * @param upwd 用户密码
     * @return
     */
    public User userlogin(@Param("uname") String uname, @Param("upwd") String upwd);

    /***
     * 根据用户id 返回用户的菜单集合
     * @param userid
     * @return
     */
    List<Menu> selectUserMenuByUserId(@Param("userid") int userid);
}



















